
#include <BApplication>
#include "ReadWrite_ico.h"
#include "MainWindow.h"

int main(int argc, char** argv)
{
	BApplication app;
	app.setCurrentPath(BString(argv[0]).path());
	app.setStyleSheet("data/style/image.css");

	ReadWrite_icon* rw_icon = new ReadWrite_icon();
	SetReadWrite("ico", rw_icon);

	MainWindow mw;
	mw.setTitle("Image Editer");
	mw.setFrameless(true);
	mw.setFont("times");
	mw.show();

	if (argc > 1)
	{
		mw.openImage(argv[1]);
		mw.setTitle(argv[1]);
	}
	else
	{
		//mw.openImage("data/image/Uniflow_steam_engine.gif");
	}
	return app.execute();
}